home *** CD-ROM | disk | FTP | other *** search
/ Internet Info 1994 March / Internet Info CD-ROM (Walnut Creek) (March 1994).iso / networking / ip / ka9q / aztecnos.arc / ECCMD.C < prev    next >
Encoding:
C/C++ Source or Header  |  1988-09-20  |  775 b   |  31 lines

  1. #include <stdio.h>
  2. #include "global.h"
  3. #include "mbuf.h"
  4. #include "iface.h"
  5. #include "ec.h"
  6. int
  7. doetherstat(argc,argv)
  8. int argc;
  9. char *argv[];
  10. {
  11.     register struct ec *ecp;
  12.     char buf[20];
  13.  
  14.     for(ecp = Ec;ecp < &Ec[Nec]; ecp++){
  15.         pether(buf,ecp->iface->hwaddr);
  16.         printf("Controller %u, Ethernet address %s\n",ecp-Ec,buf);
  17.  
  18.         printf("recv      bad       overf     drop      nomem     intrpt\n");
  19.         printf("%-10lu%-10lu%-10lu%-10lu%-10lu%-10lu\n",
  20.          ecp->estats.recv,ecp->estats.bad,ecp->estats.over,
  21.          ecp->estats.drop,ecp->estats.nomem,ecp->estats.intrpt);
  22.  
  23.         printf("xmit      timeout   jam       jam16\n");
  24.         printf("%-10lu%-10lu%-10lu%-10lu\n",
  25.          ecp->estats.xmit,ecp->estats.timeout,ecp->estats.jam,
  26.          ecp->estats.jam16);
  27.     }
  28.     return 0;
  29. }
  30.  
  31.